#include <stdio.h>

// 指针结构体变量访问成员的两种方式：
// ptr->xx  |  (*ptr).xx

int main(){

    struct Student {
        char *name;
        int age;
        int id;
    };
    struct Student stu = {"Kim", 21, 1001};
    struct Student *ptr = &stu;

    ptr->age = 22;
    (*ptr).id = 1002;

    printf("%d, %d\n", stu.age, stu.id);

    return 0;
}